#ifndef H_NYMPHAEA_COMM_CONFIG
#define H_NYMPHAEA_COMM_CONFIG
/*
 * project: nymphaea
 * module: comm::config
 * purpose: tree-structured configuration
 * creation date: 2010-MAY-15
 * created by: kaby<entelechie@gmail.com>
 * license: GNU General Public License v3
 */


#include <string>

namespace Json
{
	class Value;
}

namespace nymphaea
{

namespace comm
{

class Config
{
public:
	Config();
	Config(Json::Value node);
	virtual ~Config();

	int load(const std::string& dump);
	
	Config getChild(const std::string& name) const;
	const std::string getAttribute(const std::string& name) const;
private:
	Json::Value* mpRoot;
	bool illegal;
};


}
}

#endif
